<template>
  <view class="ui-empty">
    <view class="ui-empty-container">
      <!-- 空数据的图片 -->
      <view class="empty-image">
        <slot name="img">
          <image
            class="empty-image--img"
            src="/static/images/components/empty/nodata.png"
            mode="widthFix"
          />
        </slot>
      </view>

      <!-- 空数据的描述信息 -->
      <slot name="txt">
        <text class="empty-text ui-txt txt-caption">{{text}}</text>
      </slot>
      <!-- 空数据的其他信息 -->
      <slot name="extend">
        <text class="empty-extend ui-txt txt-caption-sm" v-if="extend">{{extend}}</text>
      </slot>
    </view>
  </view>
</template>
<script>
export default {
  name: "uiEmpty",

  props: {
    text: {
      type: String,
      default: "没有数据"
    },
    extend: {
      type: String,
      default: ""
    }
  },
  components: {},
  data() {
    return {};
  },
  methods: {}
};
</script>

<style lang="scss" src="@/scss/components/empty.scss">
</style>
